package com.itheima.factory;

import com.itheima.dao.TeacherDao;
import com.itheima.dao.impl.TeacherDaoImpl;
import org.springframework.beans.factory.FactoryBean;

public class TeacherFactory implements FactoryBean<TeacherDao> {

    @Override
    public TeacherDao getObject() throws Exception {
        System.out.println("TeacherFactory == TeacherDao == 执行咯");
        return new TeacherDaoImpl();
    }

    @Override
    public Class<?> getObjectType() {
        return TeacherDao.class;
    }
}
